Error situations and unspecified behavior

error When speaking of an error situation, this report uses the phrase ``an error is signalled'' to indicate that implementations must detect and report the error. If such wording does not appear in the discussion of an error, then implementations are not required to detect or report the error, though they are encouraged to do so. An error situation that implementations are not required to detect is usually referred to simply as ``an error.''

For example, it is an error for a procedure to be passed an argument that the procedure is not explicitly specified to handle, even though such domain errors are seldom mentioned in this report. Implementations may extend a procedure's domain of definition to include such arguments.

This report uses the phrase ``may report an implementation error'' to indicate circumstances under which an implementation is permitted to report that it is unable to continue execution of a correct program because of some arbitrary restriction imposed by the implementation. When an implementation error is reported, the report must make clear that the implementation is at fault. Implementation restrictions are of course discouraged.

For example, an implementation may report an implementation error if it does not have enough storage to run a program.

If the value of an expression is said to be ``unspecified,'' then the expression must evaluate to some object without signalling an error, but the value depends on the implementation; this report explicitly does not say what value should be returned.

Talk about unspecified behavior vs. unspecified values.

Look at KMP's situations paper.